<template>
  <div id="app">
    <keep-alive>
			<router-view v-if="$route.meta.isRoot" />
		</keep-alive>

		<router-view v-if="!$route.meta.isRoot" />

    <van-tabbar :placeholder="true" route v-model="active" v-if="$route.meta.isRoot" active-color="#5E81B5"
      inactive-color="#333">
      <!-- <van-tabbar-item   icon="home-o">首页</van-tabbar-item> -->
      <van-tabbar-item replace to="/" icon="home-o">
        首页
      </van-tabbar-item>
      <van-tabbar-item replace to="/publish" icon="add-o">发布</van-tabbar-item>
      <van-tabbar-item replace to="/my" icon="friends-o">我的</van-tabbar-item>
    </van-tabbar>
  </div>
</template>

<script>
export default {
  data() {
    return {
      active: 0
    }
  },
}
</script>
<style lang="scss">
* {
  margin: 0;
  padding: 0;
}

em {
  font-style: normal;
}

li {
  list-style: none;
}

.icon {
  width: 1em;
  height: 1em;
  vertical-align: -0.15em;
  fill: currentColor;
  overflow: hidden;
}
html,body,#app {
    height:100%;
}
</style>
